import fetch from '../utils/fetch'
import config from '../utils/config'
import { querystring } from 'vux'

var ZBPublishService = {
  getZBPublish () {
    var data = {
      action: 'GetZBPublish'
    }
    var url = config.API_SERVER + '/WXApi.ajax?' + querystring.stringify(data)
    return fetch({
      url: url,
      method: 'GET'
    })
  },
  getZBPublishDetail (publicMsgGUID) {
    var data = {
      action: 'GetZBPublishDetail',
      PublicMsgGUID: publicMsgGUID
    }
    var url = config.API_SERVER + '/WXApi.ajax?' + querystring.stringify(data)
    return fetch({
      url: url,
      method: 'GET'
    })
  }
}

export default ZBPublishService
